import Vue from 'vue'
import VueRouter from 'vue-router'

const Home = () => import(/* webpackChunkName: "login_Home_Welcome" */ '../components/Home.vue')

const Welcome = () => import(/* webpackChunkName: "login_Home_Welcome" */ '../components/Welcome.vue')

const Bookings = () => import(/* webpackChunkName: "login_Home_Welcome" */ '../components//bookings/Bookings.vue')

Vue.use(VueRouter)

const routes = [
  { path: '/', redirect: '/home' },
  { 
    path: '/home', 
    component: Home,
    redirect: '/3',
    children: [
    {
      path: '/welcome', component: Welcome
    },
    {
      path: '/3', component: Bookings
    },
  ]
  }

]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
